from classpath import entry
from zipfile import  ZipFile


class ZipEntry(entry.IEntry):
    absPath=''

    def __init__(self,absPath):
        self.absPath=absPath

    def readClass(self,className):
        zipFile=ZipFile(self.absPath, 'r')
        # for f in zipFile.namelist():
        #     print(f)
        return zipFile.open(className).read()

    def String(self):
        return self.absPath
